﻿using ThunderboltIocFrame.Interface;


namespace ThunderboltIocFrame.Implement;

public class Container : IContainer
{
    private readonly IServiceCollection _collection;


    public Container(IServiceCollection collection)
    {
        _collection = collection;
    }
    public TService Get<TService>(string key = "")
    {
        return (TService)_collection[key].GetInstance();
    }
   
    
}